﻿Public Class Custom_DGVTextBoxColumn
    Inherits System.Windows.Forms.DataGridViewTextBoxColumn
    Public Event AfterVaueChange As Custom_DGVcomboBoxColEventHandler
    Dim _AllowNull As Boolean
    Protected Overloads Sub Paint(ByVal [source] As System.Windows.Forms.CurrencyManager, ByVal rowNum As Integer, ByVal colNum As Integer, ByVal CellValue As Object)
        Dim e As Custom_DGVcomboBoxColEventArgs = Nothing
        'col = DataGridView.Columns.IndexOf(Me)
        e = New Custom_DGVcomboBoxColEventArgs(rowNum, colNum, CellValue)
        RaiseEvent AfterVaueChange(Me, e)

        If Val(e.CurrentCellValue) < 0 Then
            MsgBox("Qty Do not null", MsgBoxStyle.Critical)
        End If
    End Sub
    Public Property AllowNull() As Boolean
        Get
            Return _AllowNull
        End Get
        Set(ByVal value As Boolean)
            _AllowNull = value
        End Set
    End Property

End Class
